Methods and systems for training an object detection algorithm using synthetic images

ABSTRACT

A method includes: (A) receiving a selection of a 3D model stored in one or more memories, the 3D model corresponding to an object and (B) setting a camera parameter set for a camera for use in detecting a pose of the object in a real scene. The method also includes (C) generating at least one 2D synthetic image based at least on the camera parameter set by rendering the 3D model in a view range for generating training data.

This application is a continuation application of U.S. patentapplication Ser. No. 16/572,750, filed Sep. 17, 2019, which is acontinuation application of U.S. patent application Ser. No. 15/839,247,filed on Dec. 12, 2017. The entire disclosure of each reference ishereby incorporated by reference in its entirety.

BACKGROUND 1. Technical Field

The disclosure relates generally to the field of training objectdetection algorithms, and more specifically to methods and systems fortraining object detection algorithms using synthetic two-dimensional(2D) images.

2. Related Art

Augmented Reality (AR) has become increasingly common with theadvancement of computer technology. A general definition of AR iscapturing a real-world scene and adding artificial (virtual) elementsusing software. This can enhance a user□s perception of the real worldor provide entertainment to the user.

Object tracking is used in many AR implementations. In object tracking,a real-world object is “followed” by an artificial object, such ascomputer-graphics enhancements or an information bubble (as perceived bythe user). In other words, if the real-world object moves or the user□sview moves relative to the real-world object, the artificial object willremain in the same location relative to the real-world object and/or thecontent of the artificial object will be determined based on themovement and/or new location of the real-world object. Location trackingis also used in many AR implementations. In location tracking, a virtualobject will stay in one location in the scene, regardless of themovement of the user.

One platform for implementing AR is the smartphone. The presence of acamera, display device, and processor on the same device allows forsoftware to easily add artificial elements to a live scene captured bythe camera. Moreover, the presence of motion sensors and locators (e.g.accelerometers and GPS) on these devices is exploited by the software tobetter implement AR.

Although smartphones provide a simple and convenient platform forimplementing AR, they do not provide a very immersive experience for theuser. This is because the user□s eyes are spatially separated from thesmartphone, and instead of perceiving the environment with their owneyes, they are viewing the scene as captured by the camera.

SUMMARY

To improve on the AR experience, the transparent head-mounted display(HMD) can implement AR. These systems are usually glasses with prismsplaced in front of the eyes. The user views the scene directly throughthe glasses. The prisms allow for artificial images to be overlaid onthe scene as perceived by the user. Meanwhile, the HMD collects datafrom the scene using a camera.

3D pose estimation is an important technology with many applications,including the fields of AR, VR and robotics.

Trackers commonly utilize an initialization method to first starttracking and to re-start tracking in case of tracking loss. This mayrequire estimating the pose of an object from an image without priorhistory, a technology sometimes referred to as object detection and poseestimation (ODPE).

Object detection algorithms are commonly trained to recognize specificobjects using images of the object captured with a camera that is to beused for the AR system. In at least some known systems, the initialstages of the training process are time consuming and performedmanually. In such manual training, a trainer positions the object,captures numerous images of the object from numerous different angles ofview using the camera of the AR system, and uploads the images to atraining computer. Using the training computer, the trainer aligns athree-dimensional (3D) model of the object to the image of the object ineach captured image.

An advantage of some aspects of the disclosure is to solve at least apart of the problems described above, and aspects of the disclosure canbe implemented as the following aspects.

One aspect of the disclosure is a non-transitory computer readablemedium that embodies instructions that cause one or more processors toperform a method. The method includes: (A) receiving a selection of a 3Dmodel stored in one or more memories, the 3D model corresponding to anobject, and (B) setting a camera parameter set for a camera for use indetecting a pose of the object in a real scene. Setting the cameraparameter set includes receiving information identifying anAugmented-Reality (AR) device including the camera, and acquiring, basedat least in part on the information identifying the AR device, thecamera parameter set for the camera from a plurality of the cameraparameter sets stored in one or more memories. Each camera parameter setof the plurality of camera parameter sets is associated in the one ormore memories with at least one AR device of a plurality of different ARdevices. The method also includes (C) generating at least one 2Dsynthetic image based on the camera parameter set by rendering the 3Dmodel in a view range, (D) generating training data using the at leastone 2D synthetic image to train an object detection algorithm, and (E)storing the generated training data in one or more memories.

Another aspect of the present disclosure is a non-transitory computerreadable medium that embodies instructions that cause one or moreprocessors to perform a method. The method includes: (A) receiving aselection of a 3D model stored in one or more memories, the 3D modelcorresponding to an object, and (B) setting a camera parameter set for acamera for use in detecting a pose of the object in a real scene.Setting the camera parameter set includes acquiring, through a dataconnection, the camera parameter set from an Augmented-Reality (AR)device that includes the camera when the AR device becomes accessible bythe one or more processors through the data connection. The method alsoincludes (C) generating at least one 2D synthetic image based on thecamera parameter set by rendering the 3D model in a view range, (D)generating training data using the at least one 2D synthetic image totrain an object detection algorithm, and (E) storing the generatedtraining data in one or more memories.

A further aspect of this disclosure is a non-transitory computerreadable medium that embodies instructions that cause one or moreprocessors to perform a method. The method includes: (A) receiving aselection of a 3D model stored in one or more memories, the 3D modelcorresponding to an object, and (B) setting a camera parameter set for acamera for use in detecting a pose of the object in areal scene. Themethod also includes (C) receiving a selection of data representing aview range, (D) generating at least one 2D synthetic image based on thecamera parameter set by rendering the 3D model in the view range, (E)generating training data using the at least one 2D synthetic image totrain an object detection algorithm, and (F) storing the generatedtraining data in one or more memories.

BRIEF DESCRIPTION OF THE DRAWINGS

The disclosure will be described with reference to the accompanyingdrawings, wherein like numbers reference like elements.

FIG. 1 is a diagram illustrating a schematic configuration of an exampleHMD.

FIG. 2 is a block diagram illustrating a functional configuration of theHMD shown in FIG. 1.

FIG. 3 is a block diagram illustrating a functional configuration of acomputer for performing the methods of this disclosure.

FIG. 4 is a flow diagram of an example method according to thisdisclosure.

FIG. 5 is an input window of a graphic user interface (GUI) for use withsome example methods of this disclosure.

FIG. 6 is a preview window associated with the GUI input window shown inFIG. 5.

DESCRIPTION OF EXEMPLARY EMBODIMENTS

The disclosure relates generally to training object detectionalgorithms, and more specifically to methods and systems for trainingobject detection algorithms using synthetic two-dimensional (2D) images.

In some embodiments, the trained object detection algorithm is used byan object detection device, such as an AR device. Some example systemsinclude and/or interface with an AR device. In still other embodiments,the methods described herein for training an object detection algorithmare performed by the AR device itself.

The AR device may be, for example, an HMD. An example HMD suitable foruse with the methods and systems described herein will be described withreference to FIGS. 1 and 2.

FIG. 1 is a schematic configuration of an HMD 100. The HMD 100 is ahead-mounted display device (a head mounted display). The HMD 100 is anoptical transmission type. That is, the HMD 100 can cause a user tosense a virtual image and, at the same time, cause the user to directlyvisually recognize an outside scene.

The HMD 100 includes a wearing belt 90 wearable on the head of the user,a display section 20 that displays an image, and a control section 10that controls the display section 20. The display section 20 causes theuser to sense a virtual image in a state in which the display section 20is worn on the head of the user. The display section 20 causing the userto sense the virtual image is referred to as “display AR” as well. Thevirtual image sensed by the user is referred to as AR image as well.

The wearing belt 90 includes a wearing base section 91 made of resin, abelt 92 made of cloth coupled to the wearing base section 91, a camera60, and an IMU (Inertial Measurement Unit) 71. The wearing base section91 has a shape curved along the form of the frontal region of a person'sforehead. The belt 92 is worn around the head of the user.

The camera 60 functions as an imaging section. The camera 60 is capableof imaging an outside scene and disposed in a center portion of thewearing base section 91. In other words, the camera 60 is disposed in aposition corresponding to the center of the forehead of the user in astate in which the wearing belt 90 is worn on the head of the user.Therefore, the camera 60 images an outside scene, which is a real sceneon the outside in a line of sight direction of the user, and acquires acaptured image, which is an image captured by the camera 60, in thestate in which the user wears the wearing belt 90 on the head.

The camera 60 includes a camera base section 61 that rotates withrespect to the wearing base section 91 and a lens section 62, a relativeposition of which is fixed with respect to the camera base section 61.The camera base section 61 is disposed to be capable of rotating alongan arrow CS1, which indicates a predetermined range of an axis includedin a plane including the center axis of the user, when the wearing belt90 is worn on the head of the user. Therefore, the direction of theoptical axis of the lens section 62, which is the optical axis of thecamera 60, can be changed in the range of the arrow CS1. The lenssection 62 images a range that changes according to zooming centering onthe optical axis.

The IMU 71 is an inertial sensor that detects acceleration. The IMU 71can detect angular velocity and terrestrial magnetism in addition to theacceleration. The IMU 71 is incorporated in the wearing base section 91.Therefore, the IMU 71 detects acceleration, angular velocity, andterrestrial magnetism of the wearing belt 90 and the camera base section61.

A relative position of the IMU 71 to the wearing base section 91 isfixed. Therefore, the camera 60 is movable with respect to the IMU 71.Further, a relative position of the display section 20 to the wearingbase section 91 is fixed. Therefore, a relative position of the camera60 to the display section 20 is movable.

The display section 20 is coupled to the wearing base section 91 of thewearing belt 90. The display section 20 is an eyeglass type. The displaysection 20 includes a right holding section 21, a right display drivingsection 22, a left holding section 23, a left display driving section24, a right optical-image display section 26, and a left optical-imagedisplay section 28.

The right optical-image display section 26 and the left optical-imagedisplay section 28 are located in front of the right eye and the lefteye of the user when the user wears the display section 20. One end ofthe right optical-image display section 26 and one end of the leftoptical-image display section 28 are connected to each other in aposition corresponding to the middle of the forehead of the user whenthe user wears the display section 20.

The right holding section 21 has a shape extending in a substantialhorizontal direction from an end portion ER, which is the other end ofthe right optical-image display section 26, and inclining obliquelyupward halfway. The right holding section 21 connects the end portion ERand a coupling section 93 on the right side of the wearing base section91.

Similarly, the left holding section 23 has a shape extending in asubstantial horizontal direction from an end portion EL, which is theother end of the left optical-image display section 28 and incliningobliquely upward halfway. The left holding section 23 connects the endportion EL and a coupling section (not shown in the figure) on the leftside of the wearing base section 91.

The right holding section 21 and the left holding section 23 are coupledto the wearing base section 91 by left and right coupling sections 93 tolocate the right optical-image display section 26 and the leftoptical-image display section 28 in front of the eyes of the user. Notethat the coupling sections 93 couple the right holding section 21 andthe left holding section 23 to be capable of rotating and capable ofbeing fixed in any rotating positions. As a result, the display section20 is provided to be capable of rotating with respect to the wearingbase section 91.

The right holding section 21 is a member provided to extend from the endportion ER, which is the other end of the right optical-image displaysection 26, to a position corresponding to the temporal region of theuser when the user wears the display section 20.

Similarly, the left holding section 23 is a member provided to extendfrom the end portion EL, which is the other end of the leftoptical-image display section 28 to a position corresponding to thetemporal region of the user when the user wears the display section 20.The right display driving section 22 and the left display drivingsection 24 are disposed on a side opposed to the head of the user whenthe user wears the display section 20.

The display driving sections 22 and 24 include liquid crystal displays241 and 242 (hereinafter referred to as “LCDs 241 and 242” as well) andprojection optical systems 251 and 252 explained below. Theconfiguration of the display driving sections 22 and 24 is explained indetail below.

The optical-image display sections 26 and 28 include light guide plates261 and 262 and dimming plates explained below. The light guide plates261 and 262 are formed of a light transmissive resin material or thelike and guide image lights output from the display driving sections 22and 24 to the eyes of the user.

The dimming plates are thin plate-like optical elements and are disposedto cover the front side of the display section 20 on the opposite sideof the side of the eyes of the user. By adjusting the lighttransmittance of the dimming plates, it is possible to adjust anexternal light amount entering the eyes of the user and adjustvisibility of a virtual image.

The display section 20 further includes a connecting section 40 forconnecting the display section 20 to the control section 10. Theconnecting section 40 includes a main body cord 48 connected to thecontrol section 10, a right cord 42, a left cord 44, and a couplingmember 46.

The right cord 42 and the left cord 44 are two cords branching from themain body cord 48. The display section 20 and the control section 10execute transmission of various signals via the connecting section 40.As the right cord 42, the left cord 44, and the main body cord 48, forexample, a metal cable or an optical fiber can be adopted.

The control section 10 is a device for controlling the HMD 100. Thecontrol section 10 includes an operation section 135 including anelectrostatic track pad and a plurality of buttons that can be pressed.The operation section 135 is disposed on the surface of the controlsection 10.

FIG. 2 is a block diagram functionally showing the configuration of theHMD 100. As shown in FIG. 2, the control section 10 includes a ROM 121,a RAM 122, a power supply 130, the operation section 135, a CPU 140(sometimes also referred to herein as processor 140), an interface 180,and a transmitting section 51 (Tx 51) and a transmitting section 52 (Tx52).

The power supply 130 supplies electric power to the sections of the HMD100. Various computer programs are stored in the ROM 121. The CPU 140develops or loads, in the RAM 122, the computer programs stored in theROM 121 to execute the computer programs. The computer programs includecomputer programs for realizing tracking processing and AR displayprocessing explained below.

The CPU 140 develops, in the RAM 122, the computer programs stored inthe ROM 121 to function as an operating system 150 (OS 150), a displaycontrol section 190, a sound processing section 170, an image processingsection 160, and a processing section 167.

The display control section 190 generates control signals forcontrolling the right display driving section 22 and the left displaydriving section 24. The display control section 190 controls generationand emission of image lights respectively by the right display drivingsection 22 and the left display driving section 24.

The display control section 190 transmits control signals to a right LCDcontrol section 211 and a left LCD control section 212 respectively viathe transmitting sections 51 and 52. The display control section 190transmits control signals respectively to a right backlight controlsection 201 and a left backlight control section 202.

The image processing section 160 acquires an image signal included incontents and transmits the acquired image signal to receiving sections53 and 54 of the display section via the transmitting sections 51 and52. The sound processing section 170 acquires a sound signal included inthe contents, amplifies the acquired sound signal, and supplies thesound signal to a speaker (not shown in the figure) in a right earphone32 and a speaker (not shown in the figure) in a left earphone 34connected to the coupling member 46.

The processing section 167 acquires a captured image from the camera 60in association with time. The time in this embodiment may or may not bebased on a standard time. The processing section 167 calculates a poseof an object (a real object) according to, for example, a transformationmatrix. The pose of the object means a spatial relation (a rotationaland a translational relation) between the camera 60 and the object. Theprocessing section 167 calculates, using the calculated spatial relationand detection values of acceleration and the like detected by the IMU71, a transformation matrix for converting a coordinate system fixed tothe camera 60 to a coordinate system fixed to the IMU 71. The functionof the processing section 167 is used for the tracking processing andthe AR display processing explained below.

The interface 180 is an input/output interface for connecting variousexternal devices OA, which are supply sources of contents, to thecontrol section 10. Examples of the external devices OA include astorage device having stored therein an AR scenario, a personal computer(Pc), a cellular phone terminal, and a game terminal. As the interface180, for example, a USB interface, a micro USB interface, and aninterface for a memory card can be used.

The display section 20 includes the right display driving section 22,the left display driving section 24, the right light guide plate 261functioning as the right optical-image display section 26, and the leftlight guide plate 262 functioning as the left optical-image displaysection 28. The right and left light guide plates 261 and 262 areoptical see-through elements that transmit light from real scene.

The right display driving section 22 includes the receiving section 53(Rx53), the right backlight control section 201 and a right backlight221, the right LCD control section 211 and the right LCD 241, and theright projection optical system 251. The right backlight control section201 and the right backlight 221 function as a light source.

The right LCD control section 211 and the right LCD 241 function as adisplay element. The display elements and the optical see-throughelements described above allow the user to visually perceive an AR imagethat is displayed by the display elements to be superimposed on the realscene. Note that, in other embodiments, instead of the configurationexplained above, the right display driving section 22 may include aself-emitting display element such as an organic EL display element ormay include a scan-type display element that scans a light beam from alaser diode on a retina. The same applies to the left display drivingsection 24.

The receiving section 53 functions as a receiver for serial transmissionbetween the control section 10 and the display section 20. The rightbacklight control section 201 drives the right backlight 221 on thebasis of an input control signal. The right backlight 221 is a lightemitting body such as an LED or an electroluminescence (EL) element. Theright LCD control section 211 drives the right LCD 241 on the basis ofcontrol signals transmitted from the image processing section 160 andthe display control section 190. The right LCD 241 is atransmission-type liquid crystal panel on which a plurality of pixels isarranged in a matrix shape.

The right projection optical system 251 is configured by a collimatelens that converts image light emitted from the right LCD 241 into lightbeams in a parallel state. The right light guide plate 261 functioningas the right optical-image display section 26 guides the image lightoutput from the right projection optical system 251 to the right eye REof the user while reflecting the image light along a predeterminedoptical path. Note that the left display driving section 24 has aconfiguration same as the configuration of the right display drivingsection 22 and corresponds to the left eye LE of the user. Therefore,explanation of the left display driving section 24 is omitted.

The device to which the technology disclosed as an embodiment is appliedmay be an imaging device other than an HMD. For example, the device maybe an imaging device that has no function of displaying an image.

FIG. 3 is a block diagram illustrating a functional configuration of acomputer 300 as an information processing device in the presentembodiment which performs the methods described herein. The computer 300includes a CPU 301, a display unit 302, a power source 303, an operationunit 304, a storage unit 305, a ROM, a RAM, an AR interface 309 and anetwork adaptor 310. The power source 303 supplies power to each unit ofthe computer 300. The operation unit 304 is a user interface (GUI) forreceiving an operation from a user. The operation unit 304 includes akeyboard, a mouse and a touch pad and the like and their driversoftware.

The storage unit 305 stores various items of data and computer programs,and includes a hard disk drive, a solid-state drive, or the like. Thestorage unit 305 includes a 3D model storage portion 307 and a templatestorage portion 308. The 3D model storage portion 307 stores athree-dimensional model of a target object, created by usingcomputer-aided design (CAD) or other 3D reconstruction methods. Thetraining data storage portion 308 stores training data created asdescribed herein (not shown). The storage unit 305 also storesinstructions (not shown) for execution by the CPU 301. The instructionscause the CPU 301 to perform the methods described herein. The ARinterface 309 is an interface for communicative connection to an ARdevice. The AR interface may be any wired or wireless interface suitablefor establishing a data connection for communication between thecomputer 300 and an AR device. The AR interface may be, for example, aWi-Fi transceiver, a USB port, a Bluetooth® transceiver, a serialcommunication port, a proprietary communication port, or the like. Thenetwork adaptor 310 is configured to allow CPU 301 to connect to one ormore networks to communicate with other computers, such as a servercomputer via a wireless network, so that, for example, the computer 300receives from the other computer a computer program that causes thecomputer 300 to perform functions described in the embodiments describedherein. In some embodiments, the AR device interface 309 and the networkadaptor 310 are a single adaptor suitable for performing the tasks ofboth network adaptor 310 and AR device interface 309.

The CPU 301 reads various programs (also sometimes referred to herein asinstructions) from the ROM and/or the storage unit 305 and develops theprograms in the RAM, so as to execute the various programs. Suitableinstructions are stored in storage unit 305 and/or the ROM and executedby the CPU 301 to cause the computer 300 to operate as a trainingcomputer to train the object detection algorithm as described herein. Insome embodiments, the computer 300, with the appropriate programming, isa system for training an object detection algorithm using syntheticimages. In other embodiments, the HMD 100 is the system for training anobject detection algorithm using synthetic images. In still otherembodiments, the system for training an object detection algorithm usingsynthetic images includes the computer 300 and the HMD 100.

The embodiments described herein relate to methods and systems fortraining an object detection algorithm using synthetic images, ratherthan actual images of a real-world object. As used herein, syntheticimages generally refer to 2D images that are not created using a camerato capture a representation of a 3D scene. More specifically, withrespect to training an object detection algorithm to detect arepresentation of a real-world 3D object in image frames captured by acamera, synthetic images are 2D images that are not created by a cameracapturing a representation of the real-world 3D object. Synthetic imagesmay be generated by capturing 2D images of a 3D model of an object in acomputer (e.g., a 3D CAD model of an object), drawing (whether by handor using a computer) a 2D image of the object, or the like. It should benoted that synthetic images include images of a synthetic image. Forexample, a photograph or scan of a synthetic image may itself be asynthetic image, in one embodiment. Conversely, images of an actualimage, such as a photograph or scan of a photograph of the real-world 3Dimage, may not be synthetic images for purposes of this disclosure underone embodiment.

FIG. 4 is a flow diagram of an example method 400 of training an objectdetection algorithm using synthetic images. The method 400 may beperformed by computer 300 to train an object detection algorithm for usewith the HMD 100 and will be described with reference to computer 300and HMD 100. In other embodiments, the method 400 may be performed by adifferent computer (including, e.g., the control section 10), may beused to train an object detection algorithm for a different AR device,may be used to, and/or may be used to train an object detectionalgorithm for any other device that performs object detection based onimage frames. To facilitate performance by a computer, the method 400 isembodied as instructions executable by one or more processors and storedin a non-transitory computer readable medium.

Initially, in S402, CPU 301 receives a selection of a 3D model stored inone or more memories, such as the ROM or the storage unit 305. The 3Dmodel may correspond to a real-world object that the object detectionalgorithm is to be trained to detect in 2D image frames. In the exampleembodiment, the selection is received from a user, such as by a userselection through a GUI of the computer 300.

It is noted that a 3D model is discussed herein as being used togenerate synthetic images in method 400. However, in some embodiments, a3D model may not be required and instead, electronic data other than a3D model (e.g., a 2D model, one or more 2D or 3D synthetic images, orthe like) may be used in step S402. As such, for ease of description,the steps of method 400 (and other parts of the present disclosure) aredescribed using a 3D model. However, the present disclosure is notlimited to using a 3D model under step S402 and anywhere where a 3Dmodel is referenced, it should be understood that some embodiments mayrelate to using electronic data other than a 3D model.

A camera parameter set for a camera, such as the camera 60, for use indetecting a pose of the object in a real scene is set in S404. Theimages captured by different cameras of the same real scene willtypically differ at least somewhat based on the particular constructionand components of each camera. The camera parameter set defines, atleast in part, how its associated camera will capture an image. In theexample embodiment, the camera parameter set may include the resolutionof the images to be captured by the camera and camera intrinsicproperties (or “camera intrinsics”), such as the X and Y direction focallengths (fx and fy, respectively), and the camera principal pointscoordinates (cx and cy). Other embodiments may use additional oralternative parameters for the camera parameter set. In someembodiments, the camera parameter set is set by the user, such as by auser selection through a graphical user interface (“GUI”) of thecomputer 300 (as is discussed later with regard to FIG. 5).

In some embodiments, the camera parameter set is set by the computer 300without being selected by the user. In some embodiments, a defaultcamera parameter set is set by the computer 300. The default cameraparameter set may be used when the camera that will be used in detectingthe pose of the object in the real scene is unknown or its parametersare unknown. The default camera set may include the parameters for anideal camera, a popular camera, a last camera for which a cameraparameter set was selected, or any other suitable camera parameter set.Moreover, some embodiments provide a combination of one or more of theabove-described methods of setting the camera parameter set.

According to various embodiments, the camera parameter set (S404) can beset by many different ways, including by a computer retrieving apre-stored model from a plurality of models pre-stored on a database,the computer receiving camera parameters from a connected AR device,and/or by a user directly entering (and/or modifying) into a GUI.However, the present application should not be limited to these specificembodiments. Nonetheless, the above embodiments are described hereinbelow.

First, in some embodiments, setting the camera parameter set (S404) isperformed by receiving information identifying a known AR deviceincluding the camera (S406). The information identifying the AR deviceis received from a user input, such as by selecting, through thecomputer□s GUI, the AR device from a list of known AR devices. In otherembodiments, the user may input the information identifying the ARdevice, such as by typing in a model name, model number, serial number,or the like.

The CPU 301 acquires, based at least in part on the informationidentifying the AR device, the camera parameter set for the camera(S408). The camera parameter set may be acquired from a plurality of thecamera parameter sets stored in one or more memories, such as thestorage unit 305 or a local or remote database. Each camera parameterset is associated in the one or more memories with at least one ARdevice of a plurality of different AR devices. Because multipledifferent AR devices may include the same camera, a single cameraparameter set may be associated with multiple AR devices.

In some embodiments, setting the camera parameter in S404 includesacquiring the camera parameter set from AR device that includes thecamera through a data connection when the AR device becomes accessibleby the one or more processors (S410). For example, when the HMD 100 isconnected (wired or wirelessly) to the AR device interface 309 of thecomputer 300, the CPU 301 may retrieve the camera parameter set from HMD100 (stored, for example, in the ROM 121). In other embodiments, thecomputer 300 may acquire the camera parameter set from the AR device bydetermining the camera parameter set. For example, the computer 300 maycause the camera 60 in the HMD 100 to capture one or more image framesof, for example, a calibration sheet and the computer 300 may analyzethe resulting image frame (s) to determine the camera parameter set. Instill other embodiments, the computer 300 may retrieve from the ARdevice an identification of the AR device and/or the camera in the ARdevice and retrieve the appropriate camera parameter set from the one ormore memories based on the retrieved identification. As mentioned above,the various techniques may be combined. For example, in someembodiments, if the AR device is available to the computer (e.g., it isconnected to AR device interface 309), the camera parameter set isacquired from the camera, and if the AR device is not available to thecomputer the setting of S406 and S408 is performed.

Once the camera parameter set is set, the CPU 301 generates at least one2D synthetic image based on the camera parameter set by rendering the 3Dmodel in a view range (S414). The view range is the range of potentiallocations of the camera 60 around the stationary object for which imageswill be synthesized. In the example embodiment, the view range includesan azimuth component and an elevation component. The view range may alsoinclude a distance component that sets a distance of the potentiallocations in the view range from the 3D model of the object. The viewrange generally defines an area on the surface of a sphere having aradius equal to the length of the distance component. Each view pointwithin the view range for which a synthetic image is generatedrepresents a different pose of the object.

In some embodiments, the CPU 301 receives selection of data representingthe view range (S412) before generating the at least one 2D syntheticimage. The selection may be received, for example, from a user selectionvia a GUI, such as the GUI shown and discussed later for FIG. 5. In someembodiments, the GUI includes a preview view of the object and agraphical representation of the user selected view range. In someembodiments, the view range is a single pose of the object selected bythe user. In other embodiments, the view range is a predetermined (e.g.,a default) view range. Instill other embodiments, the CPU 301 utilizesthe predetermined view range unless the user provides a differentselection of the view range (or modification of the predetermined viewrange. In some embodiments the predetermined view range is less than 360degrees around the object in one or more of the azimuth or elevation.The view range will be explained in more detail below with reference toFIGS. 5 and 6.

The CPU 301 generates at least one 2D synthetic image of the 3D modelrepresenting the view of the 3D model from a location within the viewrange. The number of 2D synthetic images to be generated may be fixed,variable, or user selectable. Any suitable number of images may begenerated as long as at least one 2D synthetic image is generated. If asingle 2D synthetic image is generated, the image is generated for acentral point within the view range. If more than one image isgenerated, the images are generated relatively evenly throughout theview range. In some embodiments, if the number of views is fixed or setby the user, the computer 300 determines how far apart within the viewrange to separate each image to achieve some distribution of imageswithin the view range such as an even distribution (e.g., so that eachimage is a view from a same distance away from the view of each adjacentimage). In other embodiments, the computer 300 generates a variablenumber of images, based on the size of the view range and a fixedinterval for the images. For example, the computer may generate an imagefrom a viewpoint every degree, every five degrees, every ten degrees,every twenty degrees in azimuth and elevation within the view range. Theintervals above are examples and any other suitable interval, includingless than a full degree interval, may be used. The interval betweenimages does not need to be the same for azimuth and elevation.

The computer 300 generates the at least one 2D synthetic image based onthe camera parameter set that was set in S404. The camera parameter setalters the rendering of the 3D object for the view point of the image toreplicate a real image of the real-world object taken from the sameviewpoint. In this embodiment, a process of generating synthetic imagesuses a rigid body transformation matrix for transforming 3D coordinatevalues of 3D points represented in the 3D model coordinate system toones represented in an imaginary camera coordinate system, and aperspective projection transformation matrix for projecting thetransformed 3D coordinate values to 2D coordinate values on the virtualplane of the synthetic images. The rigid body transformation matrixcorresponds to a viewpoint, or simply a view, and is expressed by arotation matrix representing rotations around three axes which areorthogonal to each other, and a translation vector representingtranslations along the three axes. The perspective projectiontransformation matrix includes camera parameters, and is appropriatelyadjusted so that the virtual plane corresponds to an imaging surface ofa camera, such as camera 60. The 3D model may be a CAD model. For eachview, the computer 300 transforms and projects 3D points on the 3D modelto 2D points on the virtual plane so that a synthetic image isgenerated, by applying rigid body transformation and perspectiveprojection transformation to the 3D points.

In S416, the computer 300 generates training data using the at least one2D synthetic image to train an object detection algorithm. The trainingdata based on the synthetic image may be generated using any techniquesuitable for use with real images. In some embodiments, generating thetraining data includes generating an appearance template and/or a shapetemplate using the 2D synthetic image (S418). The appearance templateincludes one or more features such as color, surface images or text,corners, and the like. The appearance template may include, for example,coordinate values of the locations of features of the object in the 2Dsynthetic image and their characterization, the coordinates of locationson the 3D model that correspond to those 2D locations, and the 3D modelin the pose for which the 2D image was generated. The shape templatedescribes the shape of the object in two dimensions without the surfacefeatures that are included in the appearance template. The shapetemplate may include, for example, coordinate values of points (2Dcontour points) included in a contour line (hereinafter, also simplyreferred to as a □contour□) representing an exterior of the object inthe 2D synthetic image, the points on the 3D model that correspond tothe 2D contour points, and the 3D model in the pose for which the 2Dimage was generated. In some embodiments, separate shape and appearancetemplates are created for each synthetic image generated for the viewrange. In other embodiments, data for multiple images may be stored in asingle template.

The generated training data is stored in one or more memories (S419). Insome embodiments, the training data is stored in the computer□s trainingsystem memory 305. In some embodiments, when the HMD100 iscommunicatively coupled to the computer 300 through the AR deviceinterface 309, the training data is stored by the computer 300 in thememory (such as ROM 121) of the HMD 100. In other embodiments, thetraining data is stored in the computer□s training system memory 305 andthe HMD 100.

After the training data is stored in the HMD 100, the HMD 100 mayoperate to detect the object based on the training data. In someembodiments, the HMD attempts to detect the object in image frames of areal scene captured by the camera 60 by attempting to find a matchbetween the template (s) and the image using the HMD□s object detectionalgorithm.

In some embodiments, training data is generated for multiple camerasand/or AR devices for use in detecting a pose of the object in a realscene. In some such embodiments, setting the camera parameter set inS404 includes setting a plurality of camera parameter sets for aplurality of cameras, S414 includes generating a plurality of 2Dsynthetic images based at least on the plurality of camera parametersets, and S416 includes generating training data using the plurality of2D synthetic images to train an object detection algorithm for aplurality of AR devices having the plurality of cameras. In otherembodiments, steps S404, S414, and S416 (optionally including one ormore of S406, S408, S410, S412, and S418) are simply repeated multipletimes, each time for a different camera.

As mentioned above, in some embodiments, the computer performing themethod 400 includes a GUI for providing information to and receivingselections from a user. FIGS. 5 and 6 are images of a GUI that may beused as part of a system that implements method 400. For example, theGUI may be displayed by the computer 300 on the display unit 302 and beresponsive to user input via the operation unit 304. FIG. 5 is a GUI 500for receiving input from the user, and FIG. 6 is a preview window 600displaying a 3D model 602 of the object to assist in selection and/orpreview of the view range. While the GUI shown in FIGS. 5 and 6 will bedescribed with reference to the method 400, it should be understood thatthe method 400 may be performed without using the GUI of FIGS. 5 and 6,and the GUI shown in FIGS. 5 and 6 may be used to perform training withmethods other than the method 400.

Turning initially to FIG. 5, the GUI 500 includes a model loading button502 and a selected model display field 504 used to implement S402 of themethod 400. In the example embodiment, when the user selects the modelloading button 502, another window is opened to allow the user to browseto the location (on the computer 300, database or other storage location(whether local or remote)) at which a 3D model to be selected fortraining is located. The selected model display field 504 displays thelocation of the selected model, if a model has been selected. In someembodiments, the user may select the model by typing the locationdirectly into the selected model display field 504. Moreover, in someembodiments, the user may select the model by any other suitabletechnique, including by dragging and dropping the model into the GUI500.

The camera parameter set may be set in S404 by selecting the AR devicefor which the object detection algorithm is to be trained in AR deviceselection field 506. In the illustrative embodiment of FIG. 5, the ARdevice selection field 506 is a “pull down menu” or “drop down menu.”When the user selects the field 506, a list of known AR devices ispulled down for selection by the user. In some embodiments, the ARdevice may be selected by detection by the computer 300 (for example asdescribed in S410). Based on the detected/selected AR device, thecomputer 300 retrieves the camera parameter set for the camera includedin the AR device. The resolution and camera intrinsic parameters for thecamera included in the AR device in field 506 are displayed inresolution field 508 and intrinsics field 510. The resolution and cameraintrinsic parameters collectively form the camera parameter set in thisembodiment.

In some embodiments, the user may directly manually enter the cameraparameters into the intrinsics field 510 and/or the resolution field 508without having to complete step S402 by specifying a number of alreadyexisting synthetic images. Also, the user may be allowed to modify thecamera parameters that were inputted into the intrinsics field 510and/or the resolution field 508 by the computer. Moreover, in someembodiments, the user may associate an entered/modified camera parameterset with a particular AR device or camera and store the new cameraparameter set for future use.

A settings portion 512 of the GUI 500 allows the user to set and/orreview the settings for generating synthetic images of the object 602and training the object detection algorithm. The settings portionincludes an azimuth setting section 514, an elevation setting section516, a camera distance section 518, a model rotation section 520, asingle view selector 524, a lighting selector 526, an internal renderingselector 528, and a feature level selector 522.

The settings portion 512 will be described with additional reference toFIG. 6. Model rotation section 520 allows the user to select therotation of the model 602 of the object in three dimensions. In theexample embodiment, the default rotation of the model is the rotation ofthe model 602 as stored in the model file. The model 602 is displayed inthe preview window 600 according to the model rotation displayed in themodel rotation section 520. To change the rotation of the model, theuser may numerically enter the rotation in the model rotation section520 or rotate the model 602 in the preview window 600, such as byselecting and dragging the model to rotate it (using a mouse, a user□sfinger on a touchscreen, or the like). The camera distance section 518allows the user to set the distance from the model to the camera forwhich images will be synthesized. In some embodiments, the cameradistance can also be modified by using the scroll wheel on a mouse tozoom in/out, or by any other suitable control.

The model 602 is displayed in the preview window 600 oriented accordingto the rotation selection and the camera distance selection, and it ispartially surrounded by a mesh 604. The mesh 604 defines a portion of asphere around the model 602, with the model 602 located at the center ofthe sphere. In some embodiments, the mesh 604 defines a full spherearound the model 602. The mesh 604 is a visual aid to assist withvisualizing the view range for creation for the synthetic images. Themesh includes elevation lines 608 and azimuth lines. Each azimuth linetraces three hundred and sixty degrees in the azimuth direction 606 fora particular elevation. Similarly, each elevation line traces up tothree hundred and sixty degrees in the elevation direction 608 for agiven azimuth. In the illustrated example, the mesh 604 is not a fullsphere and the elevation lines trace less than a full three hundred andsixty degrees. The azimuth and elevation lines define grid sections 610.The grid sections 610 include selected grid sections 612 and unselectedgrid sections 614. The selected grid sections 612 form the view range616. The view range 616 is the range of camera locations or orientationsfor which synthetic images are generated. The user may select the viewrange by selecting grid sections 610 in the preview window or byentering the view range numerically in the azimuth setting section 514,the elevation setting section 516 of the window 500. If the user entersthe view range numerically, the appropriate grid sections 610 will beselected in the preview window 600. Conversely, if the user selects (orunselects) grid sections 610 in the preview window 600, the numericalrepresentation in the input window 500 will be correspondingly updated.

In some embodiments, the view range 616 is preset. A default/preset viewrange may be fixed (i.e., not user changeable) in some embodiments. Inother embodiments, the default/preset view range is changeable by theuser. In an example embodiment, a default view range 616 is set with arange of sixty degrees of azimuth and forty five degrees of elevation.

Returning to FIG. 5, the single view selector 524 allows the user toselect to synthesize a single view of the model 602. If the single viewselector 524 is not selected, multiple views of the model 602 aregenerated based on the selected view range. The lighting selector 526allows the user to select whether or not lighting should be simulatedwhen generating the synthetic images. The internal rendering selector528 allows the user to select whether or not internal rendering shouldbe used when generating the synthetic images.

The feature level selector 522 is used to indicate whether the model 602is a rich feature object or a low feature object, which facilitatestraining the object detection algorithm. For example, the model 602includes surface features 618 with distinct color, contrasts, shapes,etc. that may be used for object detection and tracking. Accordingly,rich feature is selected in the feature level selector 522 and theobject detection algorithm will be trained to detect such features by,for example, creation of one or more appearance templates. If the model602 did not include surface features 618, or if the user did not want touse such features, low features would be selected in the feature levelselector 522 and the object detection algorithm will be trained todetect the object without using surface features, such as by using ashape template.

When the user is ready to train the detection algorithm, the userselects the train button 532. In response, the computer 300 generatesthe synthetic image(s) according to the settings the user selected (orthe defaults), generates training data to train the object detectionalgorithm based on the synthetic image(s), and stores the training data.The stored training data is ready to be used by the AR device to detectand track the object and the user can proceed to train the algorithm fora different object or to train the algorithm to detect the same objectusing a different AR device.

The various embodiments described herein provide a system forauto-training an object detection algorithm using synthetic images. Theembodiments reduce the amount of user involvement in training thealgorithm, remove the time and effort needed to capture multiple imagesof an actual object using each particular AR device to be trained todetect the object, and remove the need to have an actual copy of theobject and the AR device to be trained.

Some embodiments provide a non-transitory storage medium (e.g. ROM 121,RAM 122, identification target storage section 139, etc.) containingprogram instructions that, when executed by a computer processor (e.g.CPU 140, processor 167, CPU 301), perform the methods described herein.

Although the invention has been described with reference to embodimentsherein, those embodiments do not limit the scope of the invention.Modifications to those embodiments or different embodiments may fallwithin the scope of the invention.

What is claimed is:
 1. A method for training an object detectionalgorithm, comprising: (A) receiving a selection of a 3D model stored inone or more memories, the 3D model corresponding to an object; (B)setting a camera parameter set for a camera for use in detecting a poseof the object in a real scene by: receiving information identifying anobject detection device including the camera, acquiring, based at leastin part on the information identifying the object detection device, thecamera parameter set for the object detection device from a plurality ofthe camera parameter sets stored in one or more memories, wherein eachcamera parameter set of the plurality of camera parameter sets isassociated in the one or more memories with at least one objectdetection device of a plurality of different object detection devices;and (C) generating at least one 2D synthetic image based at least on thecamera parameter set by rendering the 3D model in a view range forgenerating training data.
 2. The method according to claim 1, whereinthe object detection device is a head-mounted display device includingthe camera.
 3. The method according to claim 1, wherein: (B) includes:setting a plurality of camera parameter sets for a plurality of camerasfor use in detecting a pose of the object in a real scene; and (C)includes: generating a plurality of 2D synthetic images based at leaston the respective camera parameter sets by rendering the 3D model in theview range.
 4. The method according to claim 1, further comprisingreceiving, before (C), a selection of data representing the view range.5. The method according to claim 1, wherein the view range comprises apredetermined view range covering equal to or less than 360 degrees ofazimuth and elevation.
 6. The method according to claim 1, furthercomprising: (D) receiving, via a graphical user interface, a selectionof data representing the view range.
 7. The method according to claim 6,wherein (D) comprises receiving the selection of data representing theview range from a user selection on a graphical user interface includinga preview view of the object and a graphical representation of the userselected view range.
 8. A method for training an object detectionalgorithm, comprising: (A) receiving a selection of a 3D model stored inone or more memories, the 3D model corresponding to an object; (B)setting a camera parameter set for a camera for use in detecting a poseof the object in a real scene by: acquiring, through a data connection,the camera parameter set from an object detection device having thecamera when the object detection device becomes accessible by the one ormore processors through the data connection; and (C) generating at leastone 2D synthetic image based at least on the camera parameter set byrendering the 3D model in a view range for generating training data. 9.The method according to claim 8, wherein the object detection device isa head-mounted display device including the camera.
 10. The methodaccording to claim 8, wherein: (B) includes: setting a plurality ofcamera parameter sets for a plurality of cameras for use in detecting apose of the object in a real scene; and (C) includes: generating aplurality of 2D synthetic images based at least on the respective cameraparameter sets by rendering the 3D model in the view range.
 11. Themethod according to claim 8, further comprising receiving, before (C), aselection of data representing the view range.
 12. The method accordingto claim 8, wherein the view range comprises a predetermined view rangecovering equal to or less than 360 degrees of azimuth and elevation. 13.The method according to claim 8, further comprising: (D) receiving, viaa graphical user interface, a selection of data representing the viewrange.
 14. The method according to claim 12, wherein (D) comprisesreceiving the selection of data representing the view range from a userselection on a graphical user interface including a preview view of theobject and a graphical representation of the user selected view range.